package com.yan.abstract1;

public class AbstractDemo1 {
    public static void main(String[] args) {
        Zi zi = new Zi();
        zi.eat();
        zi.setAge(20);
    }
}

abstract class Fu{
    private String name;
    private int age;

    public abstract void show();

    public Fu() {

    }

    public Fu(String name, int age) {
        this.name = name;
        this.age = age;
    }

    public void eat(){

    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }
}

class Zi extends Fu{
    @Override
    public void show() {

    }

    public Zi() {
        super();
    }

    public Zi(String name, int age) {
        super(name, age);
    }


    public void eat() {
    }
}
